package com.fit.beans;

import java.util.ArrayList;
import java.util.Collection;
import java.util.List;

import org.apache.tapestry5.OptionGroupModel;
import org.apache.tapestry5.OptionModel;
import org.apache.tapestry5.util.AbstractSelectModel;

import com.fit.interfaces.Damage;
import com.fit.interfaces.RecordDamage;

public class DamageSelectModel extends AbstractSelectModel{

	private Collection<Damage> damages;
	
	
	
	
	public DamageSelectModel(Collection<Damage> damages) {

		this.damages = damages;
	}

	public List<OptionGroupModel> getOptionGroups() {
		// TODO Auto-generated method stub
		return null;
	}

	public List<OptionModel> getOptions() {
		// TODO Auto-generated method stub
		List<OptionModel> list = new ArrayList<OptionModel>();
		for (Damage record : damages) {
			list.add(new DamageOptionModel(record));
		}
		return list;
	}

}
